/*
 * GoodsContract.java
 * business
 *
 * Created by ChenTao on 2016/9/9.
 *
 * Copyright (c) 2016年 yidiandao. All rights reserved.
 */

package com.yidiandao.business.ui.main.home;

import android.graphics.Bitmap;

import com.yidiandao.business.base.BasePresenter;
import com.yidiandao.business.base.BaseView;
import com.yidiandao.business.data.event.RefreshSecondKillEvent;
import com.yidiandao.business.data.response.QueryFrameResponse;
import com.yidiandao.business.data.response.QueryHomeHeaderResponse;
import com.yidiandao.business.interfaces.RefreshLayoutStateListener;
import com.yidiandao.business.interfaces.RefreshListener;
import com.yidiandao.business.ui.widget.listview.DisplayListItem;

import java.util.List;

/** 首页-商品-契约类 */
public class HomeContract {

    public interface Presenter extends BasePresenter {

        void loadHomeData();

        List<QueryHomeHeaderResponse.Banner> getBannerList();

        /** 获取活动对话框显示的图片 */
        void getFrame();

        void onFragmentCreate();

        void startTimer();

        void onFragmentStop();

        void onFragmentStart();

        void getNewSecondKillData();

        void checkIsSign();

        void reCheckSign();


        void getUnGetGoodsFromNet(boolean showDialogDirective);
    }

    public interface View extends BaseView<Presenter>, RefreshLayoutStateListener, RefreshListener {

        void setBannerData(List<String> banners);

        List<DisplayListItem> getDisplayListItems();

        void setDisplayListItems(List<DisplayListItem> displayListItems);

        void smoothToTop();

        void toSearchActivity();

        void showFrameDialog(Bitmap bitmap, QueryFrameResponse.Frame frame);

        void autoHideFrameDialog();

        void setToolbarVisible();

        void notifyDataSetChanged();

        void onEventMainThread(RefreshSecondKillEvent event);

        void setSignTipVisible(boolean visible);

        void showUnGetGoodsTipDialog(int count);

        void setUnGetGoodsCount(int count);
    }
}
